package Test;

/**
 * @author Alger
 * @date 2021/9/7  21:33
 */
public class T9 {
    public static void main(String[] args) {
        System.out.println(a(101010));
    }
    public static int a(int n){
        int count=0;
        while (n!=0){
            n&=n-1;
            count++;
        }
        return count;
    }
}
